Image correction processing circuit, semiconductor device, and image correction processing device

ABSTRACT

The image correction processing device ( 100 ) disclosed in the description is configured by integrating a first external terminal (CAMDI) [7:0] to which digital input image data is inputted from outside of the device, an image correction processing circuit ( 200 ) applying predetermined image correction processing on the digital input image to create digital output image data, a second external terminal (CAMDO) [7:0] outputting the digital output image data to the outside of the device, an encoder circuit ( 300 ) converting the digital output image data to analog composite video-type output image data, and a third external terminal (VOUT) outputting the analog composite video-type data to the outside of the device.

TECHNICAL FIELD

The present invention relates to an image correction process circuitthat applies various image correction processes to an input image togenerate a desired output image; and to a semiconductor device (imagecorrection process device) that integrates the image correction processcircuit.

BACKGROUND ART

(First Background Art)

Conventionally, in the field of devices and systems (indoor/outdoormonitor cameras, network cameras (IP cameras), Web cameras, intercoms,and the like), an image correction process circuit, which appliesvarious image correction processes (fog erasure correction process,against-the-light correction process, brightness correction process, andthe like) to an input image to generate a desired output image, is used.

Here, the above conventional image correction process circuit,generally, has a structure in which one field of an input image isdivided into a plurality of areas; based on a luminance histogramobtained for every area, determines what kind of scene (e.g., foggy, inan against-the-light condition, or the like) the input image is; andapplies the optimum image correction process to the input image.

As an example of a conventional technology related to the abovedescription, it is possible to list a patent document 1.

(Second Background Art)

FIG. 93A and FIG. 93B both are block diagrams that show examples ofelectronic devices (indoor-outdoor monitor cameras, network cameras (IPcameras), Web cameras, vehicle cameras, intercoms, and the like) thatprocess image data.

An electronic device 900 as the conventional example includes a cameraDSP [Digital Signal Processor] 903 that applies various digital signalprocesses to input image data which are input via an AFE [Analog FrontEnd] 902 from a camera 901, thereby generating digital output imagedata.

Here, as an example of a conventional technology related to the abovedescription, it is possible to list a patent document 2.

CITATION LIST Patent Literature

-   PLT1: U.S. Pat. No. 3,981,260-   PLT2: JP-A-2004-304712

SUMMARY OF INVENTION Technical Problem

(First Problem)

Indeed, by using an image correction process circuit, it becomespossible to convert a foggy input image and an against-the-light inputimage into an output image that has high visibility; and to output theoutput image to a display device.

However, by means of a scene determination method that is employed inthe conventional image correction process circuit, there is a case wherea suitable scene determination result is not invariably obtained, sothat there is room for further improvement.

A first technical means disclosed in the present specification, in lightof the above problems, has a first object to provide an image correctionprocess circuit that is able to apply a suitable image correctionprocess to an input image to generate a desired output image; and asemiconductor device that integrates the image correction processcircuit.

(Second Problem)

However, the conventional electronic device 900 is not provided with ameans that in a case where input image data that are foggy or misty andhas poor visibility are obtained by the camera 901, applies a suitableimage correction process (fog erasure process) to the input image data.

Here, to execute the above image correction process (fog erasureprocess) by using the camera DSP 903, it needs to unnecessarily increasethe process capability of the camera DSP 903, so that there is a problemthat brings increase in the power consumption and high cost of theelectronic device 900.

Besides, because the camera DSP 903 outputs the digital output imagedata which the camera DSP 903 itself generates to later-stage circuits(semiconductor memory and the like), so as to display the output imagedata from the camera DSP 903 by means of an image display device(television broadcast receiver and the like that include an analogcomposite video input terminal only) that interacts with only an analogcomposite video input, it is necessary to additionally dispose anencoder IC that converts the digital output image data output from thecamera DSP 903 into output image data in the analog composite videoform, so that there is a problem that brings size increase and high costof the electronic device 900.

A second technical means disclosed in the present specification, inlight of the above problems, has a second object to provide an imagecorrection process device that is able to apply a suitable imagecorrection process to input image data to generates desired output imagedata.

Solution to Problem

(First Solution Means)

To achieve the first object, an image correction process circuitdisclosed in the present specification is so structured (1-1 structure)as to include:

an image correction portion that applies a predetermined imagecorrection process to an input image to generate an output image;

a calculation portion that obtains a luminance histogram for every onefield of the input image and calculates two values or all three valuesof an average luminance value, a standard deviation value and anintermediate value; and

a correction control portion that based on two values or all the threevalues of the average luminance value, the standard deviation value andthe intermediate value of the luminance histogram which are calculatedby the calculation portion, determines whether the image correctionprocess is necessary or not for the input image and a correction amountfor the image correction process, and performs control of the imagecorrection portion.

Here, the image correction process circuit having the above 1-1structure may have a structure (1-2 structure) in which the imagecorrection portion applies a foggy-image correction process to the inputimage; and

the correction control portion, based on the average luminance value andthe standard deviation value of the luminance histogram, determineswhether the foggy-image correction process is necessary or not for theinput image and the correction amount for the image correction process.

Besides, in the image correction process circuit having the above 1-2structure, the correction control portion may be so structured (1-3structure) as to determine that the foggy-image correction process isnecessary when the average luminance value of the luminance histogram islarger than a first threshold value and the standard deviation value ofthe luminance histogram is smaller than a second threshold value.

Besides, in the image correction process circuit having the above 1-3structure, the correction control portion may have a structure (1-4structure) in which when the correction control portion determines thatthe foggy-image correction process is necessary, the correction controlportion sets a larger correction amount for the foggy-image correctionprocess in a stepwise way or a continuous way when the standarddeviation value of the luminance histogram is smaller.

Besides, the image correction process circuit having the above 1-3 or1-4 structure may have a structure (1-5 structure) in which a hysteresiswidth is set in at least one of the first threshold value and the secondthreshold value.

Besides, the image correction process circuit having any one the above1-1 to 1-5 structures may be so structured (1-6 structure) as to includea register for externally setting various parameters that are referredto by the correction control portion when the correction control portiondetermines whether the image correction process is necessary or not forthe input image and the correction amount.

Besides, a semiconductor device disclosed in the present specificationis so structured (1-7 structure) as to integrate the image correctionprocess circuit having any one of the above 1-1 to 1-6 structures.

(Second Solution Means)

To achieve the second object, an image correction process devicedisclosed in the present specification is so structured (2-1 structure)as to integrate and include:

a first external terminal into which digital input image data are inputfrom outside of the device;

an image correction process circuit that applies a predetermined imagecorrection process to the digital input image data to generate digitaloutput image data;

a second external terminal from which the digital output image data areoutput to the outside of the device;

an encoder circuit that converts the digital output image into outputimage data in an analog composite video form; and

a third external terminal from which the output image data in the analogcomposite video form are output to the outside of the device.

Here, in the image correction process device having the above 2-1structure, the image correction process circuit may be so structured(2-2 structure) as to include:

a first image correction process portion that applies a first imagecorrection process, which is an image correction process based on aluminance histogram, and besides an original purpose, is likely to bringa color-component imbalance or a luminance dynamic range shortage, tothe digital input image data to generate digital intermediate imagedata; and

a second image correction process portion that applies a second imagecorrection process, which eliminates a color-component imbalance or aluminance dynamic range shortage caused by the first image correctionprocess, to the digital intermediate image data, thereby generating thedigital output image data.

Further, the image correction process device having the above 2-2structure may have a structure (2-3 structure) in which the first imagecorrection process is a foggy-image correction process, and the secondimage correction process is a color correction process or a luminancedynamic range correction process.

Besides, the image correction process device having the above 2-2 or 2-3structure may have a structure (2-4 structure) in which in the firstimage correction process portion, a valid luminance range of theluminance histogram, which is referred to during a time of calculating acorrection coefficient, is variably set.

Further, the image correction process device having the above 2-4structure may have a structure (2-5 structure) in which the first imagecorrection process portion, when deciding a correction coefficient of aframe, uses the correction coefficient of the frame and a correctioncoefficient of at least one of frames which are input before and afterthe frame, to apply a low pass filter process to the correctioncoefficient of the frame.

Advantageous Effects of Invention

According to the first and second technical means disclosed in thepresent specification, it becomes possible to apply a suitable imagecorrection process to input image data to generate desired output imagedata.

BRIEF DESCRIPTION OF DRAWINGS

FIG. 1 is a block diagram showing a first embodiment of an image processIC according to the present invention.

FIG. 2A is a schematic view showing a foggy image.

FIG. 2B is a schematic view showing a luminance histogram of a foggyimage.

FIG. 3A is a schematic view showing a not-foggy image.

FIG. 3B is a schematic view showing a luminance histogram of a not-foggyimage.

FIG. 4 is a flow chart for describing determination of whether afoggy-image correction process is necessary or not.

FIG. 5 is a view for describing a comparison determination operationover an average luminance value ACAVG of a luminance histogram and firstthreshold values (ACAVGTH1 and ACAVGTH2).

FIG. 6A is a view showing an example of a correction amount adjustmentprocess.

FIG. 6B is a view showing another example of the correction amountadjustment process.

FIG. 7 is a block diagram showing a second embodiment of an imageprocess IC according to the present invention.

FIG. 8 is a terminal arrangement view of an image process IC 100.

FIG. 9 is a terminal-function description table of the image process IC100.

FIG. 10A is a view showing a level relationship between digital data andCVBS output for every setting (during a time of 100IRE setting).

FIG. 10B is a view showing a level relationship between digital data andCVBS output for every setting (during a time of 108IRE setting).

FIG. 11A is a data transmission/reception waveform view of a dual-linetype serial interface.

FIG. 11B is a format view of a dual-line type serial interface.

FIG. 12 is a data transmission/reception waveform view of an SPI businterface.

FIG. 13 is a flow chart showing an automatic data reading sequence.

FIG. 14 is a waveform view for describing a flow of reading data from anEEPROM.

FIG. 15A is a view showing a data format (during a set time) inside ofan EEPROM.

FIG. 15B is a view showing a data format (during a stop time) inside ofan EEPROM.

FIG. 16 is a register map of the image process IC 100.

FIG. 17 is a detailed table of a polarity set register POL.

FIG. 18A is a timing chart showing a way of setting polarity of CAMCKIfor CAMDI [7:0] (when CKPOL=0).

FIG. 18B is a timing chart showing a way of setting polarity of CAMCKIfor CAMDI [7:0] (when CKPOL=1).

FIG. 19 is a detailed table of a parameter update register PARAMSET.

FIG. 20 is a detailed table of a mode register MODE.

FIG. 21 is an operation mode table of MODE [1:0].

FIG. 22 is a detailed table of an input interface format specificationregister YUVIFSET.

FIG. 23 is a detailed table of an output range conversion registerTRAM_LIM.

FIG. 24 is a detailed table of a monitor X-direction pixel size setregister DXSIZE.

FIG. 25 is a detailed table of a monitor Y-direction pixel size setregister DYSIZE.

FIG. 26 is a detailed table of a foggy-image correction, image enhancevalid X-direction start position set register ICXST.

FIG. 27 is a detailed table of a foggy-image correction, image enhancevalid Y-direction start position set register ICYST.

FIG. 28 is a detailed table of a foggy-image correction, image enhancevalid X-direction size set register ICXSIZE.

FIG. 29 is a detailed table of a foggy-image correction, image enhancevalid Y-direction size set register ICYSIZE.

FIG. 30 is a schematic view showing a valid area of a foggy-imagecorrection and an image enhance correction.

FIG. 31 is a detailed table of a pre-gamma set register PREGAMMA.

FIG. 32 is a detailed table of a luminance correction strength setregister STRENGTH.

FIG. 33 is a detailed table of a color difference correction strengthset register UV_STRENGTH.

FIG. 34 is a detailed table of a noise curb set register NOISE_SUP.

FIG. 35 is a detailed table of an edge enhancement filter set registerEDG_CNT.

FIG. 36 is a detailed table of a response time set register RESP_SET.

FIG. 37 is a detailed table of a post-filter enable register PFLT_EN.

FIG. 38 is a detailed table of output gamma characteristic registersPOFLT0 to POFLT8.

FIG. 39 is a view showing an output gamma characteristic.

FIG. 40 is a detailed table of a foggy-image correction control registerFRCTL.

FIG. 41 is a detailed table of a foggy-image correction S-curve rangeadjustment register SCRVADJ.

FIG. 42 is a table showing a relationship between a set value in SCRVADJand a foggy-image correction strength.

FIG. 43 is a detailed table of a foggy-image correction γ-curve rangeadjustment register GCRVADJ.

FIG. 44 is a table showing a relationship between a set value in GCRVADJand an offset of a γ value.

FIG. 45 is a detailed table of a histogram average luminance valueregister HAVGLUM.

FIG. 46 is a detailed table of a histogram standard dispersion registerHSTDVRC.

FIG. 47 is a detailed table of a between-fields low pass filter controlregister FR_LPF_CNT.

FIG. 48 is a detailed table of a between-fields LPF coefficient registerFR_LPF_COEF0-FR_LPF_COEF4.

FIG. 49 is a detailed table of an automatic control UV_STR adjustmentregister UV_STR_AT.

FIG. 50 is a detailed table of automatic control dispersion valuethreshold value set registers ACVRCTH1 to ACVRCTH 3.

FIG. 51 is a detailed table of automatic control average value thresholdvalue set registers ACAVGTH1, ACAVGTH2.

FIG. 52 is a detailed table of automatic control S-curve correctionregion set registers ACSCV11 to ACSCV13.

FIG. 53 is a flow chart for describing foggy-image correction automaticcontrol.

FIG. 54 is a view showing a schema of a foggy-image correction automaticcontrol algorithm.

FIG. 55 is a detailed table of a TV encoder reset register PWD.

FIG. 56 is a detailed table of a TV encoder display mode register DISP.

FIG. 57 is a detailed table of a TV encoder video mode register VIDEO.

FIG. 58 is a list showing usable setting of the TV encoder video moderegister VIDEO.

FIG. 59 is a detailed table of a TV encoder video mode register CVBS.

FIG. 60 is a detailed table of a background color register BGCOL.

FIG. 61 is a detailed table of a TV encoder color bar test registerCOLBAR.

FIG. 62 is a detailed table of a TV encoder setup register SETUP.

FIG. 63 is a detailed table of a TV encoder setup2 register SETUP2.

FIG. 64 is a detailed table of TV encoder gamma correction registersGM_A0 to GM_A2, GM_X0 to GM_X3, and GM_Y0 to GM_Y3.

FIG. 65 is a view showing a gamma correction curve.

FIG. 66 is a table showing setting examples of gamma correctionregisters GM_A0 to GM_A2, GM_X0 to GM_X3, and GM_Y0 to GM_Y3.

FIG. 67 is a detailed table of an input valid start pixel offset setregister OFS.

FIG. 68 is a detailed table of a TV encoder valid data width setregister WID_VD.

FIG. 69 is a detailed table of a TV encoder valid line width setregister HT_VD.

FIG. 70 is a detailed table of a TV encoder horizontal display positionoffset register H_POS.

FIG. 71 is a detailed table of a TV encoder vertical display positionoffset register V_POS.

FIG. 72 is a detailed table of an input valid start line offset setregister V_OFS.

FIG. 73 is a schematic view showing set contents in a display positionchange register.

FIG. 74 is a detailed table of an SPI control register SPICNT.

FIG. 75 is a detailed table of an SPI operation clock frequency divisionregister SPIDIV.

FIG. 76 is a detailed table of an SPI write data set register SPIWDATA.

FIG. 77 is a detailed table of an SPI read data set register SPIRDATA.

FIG. 78 is a detailed table of an SPI EEPROM read address set register0:SPIADR0L.

FIG. 79 is a detailed table of an SPI EEPROM read address set register1:SPIADR1L.

FIG. 80 is a detailed table of an SPI EEPROM read address set register2:SPIADR2L.

FIG. 81 is a detailed table of an SPI EEPROM read address set register3:SPIADR3L.

FIG. 82 is a detailed table of an SPI EEPROM read address bit 8 setregister SPIADR1_H.

FIG. 83 is a detailed table of an initialization register SRST.

FIG. 84 is a connection diagram showing a system example that uses theimage process IC 100.

FIG. 85A is a block diagram showing an example of an image correctionprocess device that includes a first image correction process portiononly.

FIG. 85B is a block diagram showing an example of an image correctionprocess device that includes a second image correction process portionon a stage after the first image correction process portion.

FIG. 86 is a view for describing a deviation in a luminance histogram.

FIG. 87 is a view showing a cause of flicker occurrence due to an imagecorrection process.

FIG. 88 is a block diagram showing a first structural example of thefirst image correction process portion.

FIG. 89 is a view for describing a valid area specification of aluminance histogram.

FIG. 90 is a block diagram showing a second structural example of thefirst image correction process portion.

FIG. 91A is a schematic view for describing a low pass filter process(during a time of calculating an operation parameter for a field 2).

FIG. 91B is a schematic view for describing a low pass filter process(during a time of calculating an operation parameter for a field 3).

FIG. 92A is a view showing a structural example of an electronic devicethat incorporates the image process IC according to the presentinvention.

FIG. 92B is a view showing another structural example of an electronicdevice that incorporates the image process IC according to the presentinvention.

FIG. 93A is a block diagram showing a first conventional example of anelectronic device that processes image data.

FIG. 93B is a block diagram showing a second conventional example of anelectronic device that processes image data.

DESCRIPTION OF EMBODIMENTS

First, a first embodiment of an image process IC according to thepresent invention is described.

FIG. 1 is a block diagram showing a first embodiment of the imageprocess IC according to the present invention. An image process IC 10according to the present invention is a semiconductor device whichintegrates an image correction process circuit which includes: afoggy-image correction portion 11; a luminance histogram calculationportion 12; a correction control portion 13; and a register 14. Here,although not shown in FIG. 1, in the image process IC 10, besides thefoggy-image correction portion 11, it is possible to contain a circuitblock that applies various image processes (luminance dynamic rangecorrection, brightness correction, against-the-light correction and thelike) to an input image.

The foggy-image correction portion 11 is a means that generates adesired output image by applying a foggy-image correction process to aninput image that is input from an image source 20; and outputs the imageto a display device 30. The image source 20 is a means that generatesthe input image that is input into the image process IC 10, and, forexample, as the image source 20, it is possible to use a digital videocamera that takes a dynamic image, a digital still camera that takes astill image and the like. Besides, as the image source 20, it is alsopossible to use broadcast receivers (digital television broadcastreceivers and the like) and media players (drive devices such as a videoCD, a DVD, a Blu-ray disc, a hard disc, a semiconductor memory and thelike that have a play function; besides them, personal computers and thelike that have a play function for image contents which are provided viathe Internet). The display device 30 is a means that displays the outputimage which undergoes the foggy-image correction process by the imageprocess IC 10; and as the display device 30, it is possible to use anLCD (Liquid Crystal Display), an organic EL (Electro-Luminescence)display and the like.

The luminance histogram calculation portion 12 is a means that obtains aluminance histogram for every one field (frame) of the input image thatis input from the image source 20; and calculates two values or all thethree values of an average luminance value, a standard deviation valueand an intermediate value of the luminance histograms. Here, in theexample of FIG. 1, the luminance histogram calculation portion 12 is sostructured as to calculate an average luminance value ACAVG and astandard deviation value ACVRC of the luminance histograms.

The correction control portion 13 is a means that based on two values orall the three values of the average luminance value, the standarddeviation value and the intermediate value of the luminance histogramsthat are calculated by the luminance histogram calculation portion 12,determines a correction amount and whether the foggy-image correctionprocess is necessary or not for the input image; and based on thedetermination result, performs control of the foggy-image correctionportion 11. Here, in the example of FIG. 1, the correction controlportion 13 is so structured as to include: a first comparison portion131 that compares the average luminance value ACAVG of the luminancehistograms with first threshold values (ACAVGTH1, ACAVGTH2); a secondcomparison portion 132 that compares the standard deviation value ACVRCof the luminance histograms with second threshold values (ACVRCTH1 toACVRCTH3); and a determination portion 133 that based on comparisonresults from the first comparison portion 131 and the second comparisonportion 132, determines the correction amount and whether thefoggy-image correction process is necessary or not. Here, controloperation of the foggy-image correction portion 11 by the correctioncontrol portion 13 is described in detail later.

The register 14 is a parameter storage means that performs externalsetting, from a microcomputer 40, of various parameters (the above firstthreshold value and the second threshold value are included) that arereferred to by the correction control portion 13 when determining thecorrection amount and whether the foggy-image correction process isnecessary or not for the input image.

Next, before operation description of the correction control portion 13,it is studied what kind of difference occurs in each luminance histogrambetween a foggy input image and a not-foggy input image. FIG. 2A andFIG. 2B are schematic views that show a foggy image and a luminancehistogram of the foggy image, respectively; FIG. 3A and FIG. 3B areschematic views that show a not-foggy image and a luminance histogram ofthe not-foggy image.

Generally, a foggy input image (FIG. 2A) is an image that is white(bright) as a whole and has a low contrast (narrow luminance dynamicrange) compared with a not-foggy input image (FIG. 3A). In other words,the luminance histogram of the foggy input image has a high averageluminance value and a small standard deviation value compared with theluminance histogram of the not-foggy input image (FIG. 2B, FIG. 2B).

The correction control portion 13, in light of the above study, has astructure in which the correction control portion 13, based on theaverage luminance value ACAVG and the standard deviation value ACVRC ofthe luminance histograms that are calculated by the luminance histogramcalculation portion 12, determines the correction amount and whether thefoggy-image correction process is necessary or not for the input image;and based on the determination result, performs the control of thefoggy-image correction portion 11.

FIG. 4 is a flow chart for describing determination, by the correctioncontrol portion 13 (especially, the determination portion 133), ofwhether the foggy-image correction process is necessary or not. Here, ata start time of the flow chart, it is supposed that a register valueFR_AT is set at “1 (foggy-image correction process: automatic), and aregister value FR_EN is set at “0 (fogy-image correction process: instop).”

First, before contents description of the flow chart, the above registervalue FR_AT and the register value FR_EN are described in detail. Theregister value FR_AT is a register value for setting an execution methodof the foggy-image correction process. When the register value FR_AT isset at 0, the foggy-image correction process is manually performed,while when the register value FR_AT is set at 1, the foggy-imagecorrection process is automatically performed. Here, when the registervalue FR_EN is set at 1, bit control (operation confirmation control ofthe foggy-image correction process) of the register value FR_EN is alsoautomatically performed.

The register value FR_EN is a register value for performing operationcontrol (enable control) of the foggy-image correction process andoperation confirmation of the foggy-image correction process. In a casewhere the register value FR_AT is set at “0 (foggy-image correctionprocess: manual)”, the register value FR_EN is used for the operationcontrol (enable control) of the foggy-image correction process. In otherwords, when the register value FR_EN is set at 0, the foggy-imagecorrection process is disabled, while when the register value FR_EN isset at 1, the foggy-image correction process is enabled. On the otherhand, in a case where the register value FR_AT is set at “1 (foggy-imagecorrection process: automatic)”, the register value FR_EN is used forthe operation confirmation of the foggy-image correction process. Inother words, when the register value FR_EN is set at 0, it is confirmedthat the foggy-image correction process is in stop, while when theregister value FR_EN is set at 1, it is confirmed that the foggy-imagecorrection process is in operation.

Next, contents of the flow chart shown in FIG. 4 are specificallydescribed. If the present flow chart is started, in a step S1, theaverage luminance value ACAVG of the luminance histograms and the firstthreshold value (an upper threshold value ACAVGTH1 in the step S1) arecompared and determined. Here, in a case where it is determinedACAVG≧ACAVGTH1, the flow is advanced to a step S2 (correction amountadjustment step). On the other hand, in a case where it is determinedthat ACAVG≧ACAVGTH1 is not met, the flow is advanced to a step S4.

In the step S1, in the case where it is determined ACAVG≧ACAVGTH1, inthe step S2, the foggy-image correction process in the foggy-imagecorrection portion 11 is turned on (basically, the register value=1), anadjustment process of the correction amount (correction strength) isperformed. Here, the correction amount adjustment process in the step S2is described in detail later.

On the other hand, in the step S1, in the case where it is determinedthat ACAVG≧ACAVGTH1 is not met, in the step S4, it is determined whetherthe register value FR_SN is set at 1 or not, and the average luminancevalue ACAVG of the luminance histograms and the first threshold value(in the step S4, a lower threshold value ACAVGTH2 (≦ACAVGTH1)) arecompared and determined. Here, in a case where it is determined that theregister value FR_SN is set at 1 and it is determined ACAVG≧ACAVGTH2,the flow is advanced to a step S2. On the other hand, in a case where itis determined that the register value FR_EN is not set at 1, or it isdetermined that ACAVG≧ACAVGTH2 is not met, the flow is advanced to astep S5.

In the step S4, if it is determined that the register value FR_EN is notset at 1, or it is determined that ACAVG≧ACAVGTH2 is not met, in thestep S5, the foggy-image correction process in the foggy-imagecorrection portion 11 is turned off (the register value FR_EN=0), andthe flow is advanced to the step S3.

After the correction amount adjustment process is completed in the stepS2, or after the foggy-image correction process is turned off in thestep S5, it is determined whether the register value FR_AT is set at “0(foggy-image correction process: manual)” in the step S3 or not. Here,in a case where it is determined that the register value FR_AT is notset at 0, the flow is returned to the step S1, where the averageluminance value ACAVG of the luminance histograms and the firstthreshold value (in the step S1, the upper threshold ACAVGTH1) arerepeatedly compared and determined. On the other hand, in a case whereit is determined that the register value ER_AT is set at 0, so as tochange the foggy-image correction process to the manual execution, theseries of the flow is ended.

Here, as for the first threshold value that is compared with the averageluminance value ACAVG of the luminance histograms, as described above,it is desirable that the upper threshold value ACAVGTH1 and the lowerthreshold value ACAVGTH2 are adjusted to set a predetermined hysteresiswidth. By setting such a hysteresis width, as shown in FIG. 5, when thefoggy-image correction process is in an off state (when the registervalue FR_EN=0), the foggy-image correction process is not turned onuntil the average luminance value ACAVG of the luminance histogramsreaches the upper threshold value ACAVGTH1, while when the foggy-imagecorrection process is in an on state (when the register value FR_EN=1),the foggy-image correction process is not turned off until the averageluminance value ACAVG of the luminance histograms becomes under thelower threshold value ACAVGTH2, so that it becomes possible to curb aflicker in the output image by preventing an on/off oscillation in thefoggy-image correction process. Here, it is possible to externally setboth of the upper threshold value ACAVGTH1 and the lower threshold valueACAVGTH2 into the register 14 from the microcomputer 40; in a case wherethe upper threshold value ACAVGTH1 and the lower threshold valueACAVGTH2 are set at the same value, the above hysteresis function isturned off.

Next, the correction amount adjustment process in the step S2 isdescribed in detail with reference to FIG. 6A. FIG. 6A is a view showingan example of the correction amount adjustment process. Here, ahorizontal axis in FIG. 6A indicates the standard deviation value ACVRCof the luminance histograms, and a vertical axis in FIG. 6A indicatesthe register value FRADJ for setting the correction amount (correctionstrength) for the foggy-image correction process.

In the correction amount adjustment process in the step S2, thecorrection control portion 13 performs comparison and determination ofthe average luminance value ACVRC of the luminance histograms and thesecond threshold values (ACVRCTH1 to ACVRCTH3, ACVRCTHx to ACVRCTHz),and determines whether it is necessary to apply the foggy-imagecorrection process to the input image or not; and in a case where it isnecessary to apply the foggy-image correction process to the inputimage, determines at which one of the register values FRADJ1 to FRADJ5the correction value (correction strength) is to be set.

Here, of the second threshold values, three threshold values (ACVRCTH1,ACVRCTH2, ACVRCTH3) are able to be externally set into the register 14from the microcomputer 40; and the three other threshold values(ACVRCTHx, ACVRCTHy ACVRCTHz) are so internally automatically set as toequally divide a difference between the threshold value ACVRCTH1 and thethreshold value ACVRCTH2. Accordingly, of the second threshold values,to externally set the three threshold values (ACVRCTH1, ACVRCTH2,ACVRCTH3), it is necessary to meet a relationshipACVRCTH1+4≦ACVRCTH2≦ACVRCTH3.

Besides, it is possible to externally set the register values FRADJ1 toFRADJ5 which are candidates for the correction amount into the register14 from the microcomputer 40. Here, when externally setting the registervalues FRADJ1 to FRADJ5, to set a larger correction amount for thefoggy-image correction process when the standard deviation value ACVRCof the luminance histograms becomes smaller, it is necessary to meet arelationship FRADJ5≧FRADJ4≧FRADJ3≧FRADJ2≧FRADJ1 (where FRADJ5>FRADJ1).

Here, like in the above-described first threshold values (ACAVGTH1,ACAVGTH2), also in the second threshold values (ACVRCTH1 to ACVRCTH3,ACVRCTHx to ACVRCTHz), it is desirable to set a predetermined hysteresiswidth. For example, as shown in FIG. 6A, in a case where the standarddeviation value ACVRC of the luminance histograms becomes graduallysmall (in a case where it is necessary to increase the correctionamount), the correction amount adjustment is performed along a routerepresented by a solid line, while in a case where the standarddeviation value ACVRC of the luminance histograms becomes graduallylarge (in a case where it is necessary to decrease the correctionamount), the correction amount adjustment is performed along a routerepresented by a broken line.

For example, a case is considered, in which it is determinedACVRC=ACVRCTHy in the previous time of comparison and determination; andthe current correction amount is set at the register value FRADJ. Inthis case, the correction amount is not changed to the register valueFRADJ4 until the standard deviation value ACVRC of the luminancehistograms becomes under the threshold value ACVRCTHx (see the solidline in FIG. 6A), while the correction amount is not changed to theregister value FRADJ2 until the standard deviation value ACVRC of theluminance histograms becomes equal to or over the threshold valueACAVGTHz (see the broken line in FIG. 6A). Accordingly, it becomespossible to curb a flicker in the output image by preventing thecorrection amount for the foggy-image correction process from beingfrequently changed.

Besides, in a case where the foggy-image correction process is in theoff state, at the time the standard deviation value ACVRC of theluminance histograms becomes under the threshold value ACVRCTH2, thefoggy-image correction process is turned on, and the correction amountadjustment process is performed in accordance with the standarddeviation value ACVRC of the luminance histograms (see the solid line inFIG. 6A). On the other hand, after the foggy-image correction process isturned on, even if the standard deviation value ACVRC of the luminancehistograms becomes equal to or over the threshold value ACVRCTH2, thefoggy-image correction process is kept in the on state; and at the timethe standard deviation value ACVRC becomes equal to or over thethreshold value ACVRCTH3, the foggy-image correction process is turnedoff (see the broken line in FIG. 6A). Accordingly, it becomes possibleto curb a flicker in the output image by preventing the on/offoscillation in the foggy-image correction process. Here, in a case wherethe threshold value ACVRCTH3 is set at the largest possible value thatthe standard deviation value ACVRC of the luminance histograms is ableto have, the foggy-image correction process is always kept in the onstate.

As described above, in the image process IC 10 according to the presentembodiment, the correction control portion 13 determines that thefoggy-image correction process is necessary when the average luminancevalue ACAVG of the luminance histograms is larger than the firstthreshold value (in the examples of FIG. 4 and FIG. 5, the thresholdvalue ACAVGTH1 or the threshold value ACAVGTH2) and the standarddeviation value ACVRC of the luminance histograms is smaller than thesecond threshold value (in the example of FIG. 6A, the threshold valueACVRCTH2 or the threshold value ACVRCTH3). As described above, accordingto the structure in which based on the average luminance value ACAVG andthe standard deviation value ACVRC of the luminance histograms, thecorrection amount and necessity of the foggy-image correction processfor the input image are determined, it is possible to perform a suitablescene determination without requiring an area division process of theinput image and to perform the optimum foggy-image correction processfor every scene, so that it becomes possible to improve the visibilityof the output image.

Here, the above-described determination process of the correction amountand necessity of the foggy-image correction process is performed for onefield (frame) of the input image; however, the frequency at which theinstruction contents for the foggy-image correction portion 11 areupdated based on the determination result may not be invariably onefield: it is possible to arbitrarily adjust the frequency for every 16fields, 32 fields, or 64 fields or the like in accordance with theregister setting from the microcomputer 40.

Besides, by performing a calculation process by means of software thatuses the microcomputer 40, it is possible to perform the above-describedfoggy-image correction process, the determination of the necessity ofthe foggy-image correction process and the correction amount adjustment;however, if the calculation process by means of hardware that uses theimage process IC 10 according to the present invention, it is possibleto reduce the burden on the microcomputer 40, so that it becomespossible to achieve increase in the process speed of the entire systemand cost reduction of the entire system.

Here, in the above embodiment, the structure, in which the presentinvention is applied to the foggy-image correction process circuit, isdescribed as an example; however, the application target of the presentinvention is not limited to this: the present invention is also widelyapplicable to other image correction process circuits. For example, in acase where the present invention is applied to an against-the-lightimage correction process circuit, a structure may be employed, in whichin a case where a luminance histogram is obtained for every one frame ofthe input image, the average luminance value of them is relatively low,the standard deviation value is relatively large and the intermediatevalue is relatively high, the input image is recognized to be in anagainst-the-light condition and an against-the-light correction processis performed.

Besides, in the above embodiment, the structure (see FIG. 6A) isdescribed as an example, in which when the correction control portion 13determines that the foggy-image correction process is necessary, thecorrection control portion 13 sets a larger correction amount for thefoggy-image correction process in a stepwise way when the standarddeviation value ACVRC of the luminance histograms is smaller; however,the structure of the present invention is not limited to this; forexample, a structure (see FIG. 6B) may be employed, in which when thestandard deviation value ACVRC of the luminance histograms is smaller, alarger correction amount for the foggy-image correction process iscontinuously set.

Next, a second embodiment of the image process IC according to thepresent invention is described.

FIG. 7 is a block diagram showing a second embodiment of the imageprocess

IC according to the present invention. An image process IC 100 in thepresent embodiment is a semiconductor device (digital video encoder ICwith image correction function) that integrates: an image correctionprocess circuit 200; an encoder circuit 300; a first serial interfacecircuit 400; and a second serial interface circuit 500, and has both ofa function as an NTSC/PAL digital video encoder and a function as a fogcorrection/dynamic range correction image process device. Here, althoughnot shown in FIG. 7, in the image process IC 100 in the presentembodiment, registers each of which stores an operation settingparameter for each portion of the IC are integrated.

The image correction process circuit 200 is a circuit block whichgenerates the digital output image data by applying a predeterminedimage correction process to the digital input image data that are inputfrom outside of the device, and includes: a first image correctionprocess portion 201; and a second image correction process portion 202.

The first image correction process portion 201 is a circuit block whichapplies the foggy-image correction process to the digital input imagedata that are input from outside of the device, and to which thefoggy-image correction portion 11, the luminance histogram calculationportion 12, and the correction control portion that are shown in theabove FIG. 1 correspond.

The second image correction process portion 202 is a circuit block whichfurther applies a color correction process and a luminance dynamic rangecorrection process to the input image data that are input from the firstimage correction process portion 201 and already undergo the foggy-imagecorrection process, and includes: a color correction portion 202 a; aluminance determination portion 202 b; an image enhance portion 202 c;and a calculation process portion 202 d.

The color correction process portion 202 a, based on the input imagedata that are input from the first image correction process portion 201and already undergo the foggy-image correction process, calculates acolor correction coefficient.

The luminance determination portion 202 b, based on the input image datathat are input from the first image correction process portion 201 andalready undergo the foggy-image correction process, calculates aluminance dynamic range correction coefficient.

The image enhance portion 202 c, based on the color correctioncoefficient that is input from the color correction portion 202 a andthe luminance dynamic range correction coefficient that is input fromthe luminance determination portion 202 b, calculates the final imagecorrection coefficient.

The calculation process portion 202 d, based on the final imagecorrection coefficient that is input from the image enhance portion 202c, further applies the color correction process and the luminancedynamic range correction process to the input image data that are inputfrom the first image correction process portion 201 and already undergothe foggy-image correction process.

The encoder circuit 300 is a circuit block which converts the digitaloutput image data generated by the image correction process circuit 200into output image data in an analog composite type video form, andincludes: a memory controller 301; a line memory 302; a complementportion 303; a gamma correction portion 304; a low pass filter portion305; a trap filter portion 306; low pass filter portions 307, 308;calculation portions 309 to 312; a digital/analog conversion portion313; a timing signal generation portion 314; a sub-carrier signalgeneration portion 315; and a color bar signal generation portion 316.

The memory controller 301 uses the line memory 302 to perform linebuffer control of the digital output image data that are input from theimage correction process circuit 200. The complement portion 303 appliesa complementary process (YUV (4:2:2)→YUV (4:4:4)) of missing informationto the digital output image data input from the memory controller 301;and performs an over-sampling process (13.5 MHz→27 MHz) of the digitaloutput image data.

The gamma correction portion 304 applies a gamma correction process to aluminance signal Y that is input from the complement portion 303. Thelow pass filter portion 305 applies a low pass filter process to anoutput signal from the gamma correction portion 304. The trap filterportion 306 applies a band eliminate filter process to an output signalfrom the low pass filter portion 305.

The low pass filter portions 307, 308 apply a low pass filter process tocolor signals Cb, Cr respectively that are input from the complementportion 303. The calculation process portions 309, 310 superimpose asub-carrier signal onto output signals from the low pass filter portions307, 308 respectively. The calculation process portion 311 adds anoutput signal from the calculation process portion 309 and an outputsignal from the calculation process portion 310 to each other. Thecalculation process portion 312 adds an output signal from the trapfilter portion 305 and an output signal from the calculation processportion 311 to each other. The digital/analog conversion portion 313converts a digital signal input from the calculation process portion 312into an analog signal and outputs the analog signal.

The timing signal generation portion 314 through-outputs timing signals(horizontal synchronous signal, vertical synchronous signal, clocksignal) input from outside of the device to the outside of the device asthey are, while also performing synchronous control of the sub-carriersignal generation portion 315 by using the timing signals. Thesub-carrier signal generation portion 315 generates a sub-carrier signalused for burst modulation of the color signals Cb, Cr and supplies thesignal to the calculation process portions 309, 310. The color barsignal generation portion 316 generates a color bar signal that is areference value for the output image data in the analog composite videofoam.

The first serial interface circuit 400 collaborates with peripheraldevices (CPU (Central Processing Unit and the like) to perform dual-linetype serial communication that is in conformity with the I²C(Inter-Integrated Circuit) standard.

The second serial interface circuit 500 collaborates with an EEPROM(Electrically Erasable and Programmable Read Only Memory) to performserial communication that is in conformity with the SPI (SerialPeripheral Interface) standard.

Next, external terminals of the image process IC 100 are described. FIG.8 is a terminal arrangement view of the image process IC 100; FIG. 9 isa terminal-function description table of the image process IC 100.

A 1st pin (SDI) is an SPI bus data input terminal. A 2nd pin (CAMDI7) toa 5th pin (CAMDI4) each are data input terminals (four leftmost bits[7:4]). A 6th pin (GND) is a common ground terminal. A 7th pin (VDD) isa core power-supply terminal. An 8th pin (CAMDI3) to an 11th pin(CAMDI0) each are data input terminals (four rightmost bits [3:0]). A12th pin (CAMHSI) is a horizontal timing input terminal. A 13th pin(CAMVSI) is a vertical timing input terminal. A 14th pin (CAMCKI) is aclock input terminal. A 15th pin (GND) is a common ground terminal. A16th pin (VDDIO) is a digital I/O power-supply terminal. A 17th pin(CAMDO0) to a 24th pin (CAMDO7) each are data output terminals (8 bitsin total [7:0]). A 25th pin (CAMHSO) is a horizontal timing outputterminal. A 26th pin (CAMVSO) is a vertical timing output terminal. A27th pin (CAMCKO) is a clock output terminal. A 28th pin (GND) is acommon ground terminal. A 29th pin (VDD) is a core power-supplyterminal. A 30th pin (AUTO) is a automatic register setting functionvalid terminal. A 31st pin (MODE0) and a 32nd pin (MODE1) are modeselection terminals. A 33rd pin (VOUT) is an analog composite videooutput terminal. A 34th pin (AVSS) is a DAC analog ground terminal. A35th pin (IREF) is a DAC reference voltage output terminal. A 36th pin(AVDD) is a DAC analog power-supply terminal. A 37th pin (GND) is acommon ground terminal. A 38th pin (VDDI2C) is a dual-line type serialinterface digital I/O power-supply terminal. A 39th pin (SDA) is adual-line type serial interface digital input/output data terminal. A40th pin (SDC) is a dual-line type serial interface digital input/outputclock terminal. A 41st in (RESETB) is a system reset signal inputterminal. A 42nd pin (TEST) is a test mode terminal, and is connected tothe ground during a use time. A 43rd pin (GND) is a common groundterminal. A 44th pin (VDDIO) is a digital I/O power-supply terminal. A45th pin (WPB) is an EEPROM write protect terminal. A 46th pin (SCEB) isan EEPROM chip select terminal. A 47th pin (SCK) is an SPI bus clockoutput terminal. A 48th pin (SDO) is an SPI bus data output terminal.

Here, as for the terminals indicated by * in an active level section inFIG. 9, it is shown that by setting the registers, it is possible tochange the active level. Besides, an Init section in FIG. 9 shows pinstates during in a reset release time. Besides, it is shown that theterminals indicated by *1 in the Init section are in a pull-down state.Besides, as for the numbers described in a power-supply system sectionin FIG. 9, 1 indicates VDDIO, 2 indicates VDDI2C, 3 indicates AVDD, and4 indicates VDD.

Of the above-described external terminals, the 2nd pin (CAMDI7) to the5th pin (CAMDI4) and the 8th pin (CAMDI3) to the 11th pin (CAMDI0)correspond to the first external terminals into which the digital inputimage data are input from outside of the IC. Besides, the 17th pin(CAMDO0) to the 24th pin (CAMDO7) correspond to the second externalterminals from which the digital output image data are output to theoutside of the IC. Besides, the 33rd pin (VOUT) corresponds to the thirdexternal terminal from which the output image data in the analogcomposite video form are output to the outside of the IC.

Next, an overview of the image process IC 100 having the above structureis described. The image process IC 100 is a video encoder incorporatingan image correction function that is able to improve the visibility ofthe input image (especially, foggy input image, low-brightness inputimage, or input image in an against-the-light condition) that are inputfrom a camera and the like by comprehensively performing the foggy-imagecorrection, the color correction process, and the luminance dynamicrange correction process).

Next, features of the image process IC 100 having the above structureare described. A first feature is that an input data format iscompatible with the ITU-R BT.656-4 and the YCbCr with a synchronoussignal. Here, as for the ITU-R BT. 656-4, the data bus width is 8 bitsand the pixel clock is 27 MHz. Besides, as for the YCbCr with thesynchronous signal (the synchronous signal is for slave operation), thedata bus width is 8 bits; and the data range is a full range or inconformity with the ITU-R BT. 601. The pixel clock is NTSC (27 MHz,28.63636 MHz, or 19.06993 MHz), or PAL (27 MHz, 28.375 MHz, 35.46895MHz, or 18.9375 MHz). A second feature is that an output data format aswell, like the input format, is compatible with the ITU-R BT. 656-4, orthe YCbCr with the synchronous signal. A third feature is that an outputvideo format is compatible with an NTSC/PAL SD-TV composite video output(CVBS). A fourth feature is that the image process IC 100 incorporatesthe image correction functions (foggy-image correction function, colorcorrection function, luminance dynamic range correction function), anedge enhancement filter, and a gamma filter. A fifth feature is that theimage process IC 100 incorporates one channel of a 10-bit digital/analogconverter. A sixth feature is that the image process IC 100 incorporatesa slave function which uses the dual-line type serial interface, and isale to set the registers in the inside of the IC from outside. A seventhfeature is that that the image process IC 100 incorporates an SPI busmaster function, and is able to automatically read the register setvalues stored in an external EEEPROM at reset release and mode changetimes and to set the values into the registers in the inside of the IC.An eighth feature is that the image process IC 100 is compatible withfour-system power-supply voltages (VDD=1.50 V, VDDI0=3.30 V, VDDI2C=3.30V, AVDD=3.30 V). A ninth feature is that the image process IC 100employs a 48-pin VQFP package (0.5 mm pin pitch).

Next, a level relationship between the digital data and the CVBS outputis described. By means of an ITU601R_I register, it is possible to setan input digital data range. Besides, by means of a LEVEL register, itis possible to set an analog signal level when performing the CVBSoutput of the digital data. Relationships between the digital data rangeby the ITU601R_I register and the CVBS output level by the LEVELregister are as shown in FIG. 10A and FIG. 10B. FIG. 10A and FIG. 10Beach are views showing a level relationship between the digital data andthe CVBS output for every setting. Here, FIG. 10A shows a state in a 100[IRE] setting time, while FIG. 10B shows a state in a 108 [IRE] settingtime.

Next, the dual-line type serial interface is described. FIG. 11A is adata transmission/reception waveform view of the dual-line type serialinterface; FIG. 11B is a format view of the dual-line type serialinterface. A slave address of the dual-line type serial interface is70h. In a case where two or more consecutive accesses are performed forboth of the write/read, a sub-address is automatically augmented.

Next, the SPI bus format is described. FIG. 12 is a datatransmission/reception waveform view of the SPI bus interface. Here,REG_WPB, REG_SCEB, SWDATA, and SRDATA in FIG. 12 are register names, andthe respective functions are as follows.

REG_WPB: specifies logic of a WP pin. The register value is output tothe WP pin as it is.

REG_SCEB: specifies logic of an SCEB pin. The register value is outputto the SCEB pin as it is.

SWADA [7:0]: specifies written data into an EEPROM. The data aretransferred with MSB first.

SRDATA [7:0]: reads data from the EEPROM. The data are converted withMSB first.

Here, it is possible to calculate the SCK clock frequency by a numericalformula: the SCK frequency=the CAMCKIfrequency÷2(SPIPREDIV+1)÷(SPIDIV+1). Here, SPIPREDIV, SPIDIV are SCKfrequency set register values that are able to be set in ranges ofSPIPREDIV=0 to 7, and SPIDIV=0 to 31. When CAMCKI is 27 MHz, SCK is 13.5MHz to 3.3 kHz.

Next, a function to automatically read data from the EEPROM by means ofthe SPI bus is described in detail. In the image process IC 100, byfixing an AUTO pin at a high level, it is possible to automatically readdata from the EEPROM and set the data into a register in the IC.

FIG. 13 is a flow chart showing the automatic data reading sequence. Ina step S101, a RESETB pin is released. In a step S102, logic levels ofMODE0 and MODE1 are confirmed and the confirmation results are saved. Ina step S103, the data reading from the EEPROM is performed. In a stepS104, it is determined whether the operation state is a set state or astop state. In a case where it is determined in the step S104 that thestate is the set state, the data are reflected onto a target index in astep S105. On the other hand, in a case where it is determined in thestep S104 that the state is the stop state, the logic levels of MODE0,MODE1 are confirmed in a step S106. In a step S107, the state of theMODE pin saved in the step S102 and the confirmation result in the stepS106 are compared with each other. Here, in a case where there is achange, the flow is returned to the step S103, while in a case wherethere is not a change, the flow is returned to the step S106.

Here, in the step S103 of FIG. 13, when reading the data from theEEPROM, as for the read start address ST_ADR of the EEPROM follows thesetting of the MODE0 pin and the MODE1 pin as follows:

[MODE1, MODE0]=[Low, Low]: ST_ADR=000h

[MODE1, MODE0]=[Low, High]: ST_ADR=080h

[MODE1, MODE0]=[High, Low]: ST_ADR=100h

[MODE1, MODE0]=[High, High]: ST_ADR=180h

FIG. 14 is a waveform view for describing the flow of reading data fromthe EEPROM. Here, *A in the figure indicates an address bit 8 of theEEPROM and *B indicates address bits 7 to 0 of the EEPROM.

Besides, in the step S105 of FIG. 13, when reflecting the data onto thetarget index, following a data format in the inside of the EEPROM, theregister values are reflected onto the IC. FIG. 15A and FIG. 15B areviews showing data formats in the inside of the EEPROM. Here, FIG. 15Ashows a data format in a set time (operation state in which the settingis performed into a register in the inside of the IC), while FIG. 15Bshows a data format in a stop time (stop state of automatic reading).

Here, data contents shown in FIG. 15A are as follows:

S_CODE: 8′ b0000_(—)0001. The image process IC 100 (hereinafter,abbreviated to the present IC if necessary) receives this code anddetermines that subsequent data are valid register values.

Index: A setting start index address of the present IC

Size: Set size (byte)

Data: set data. The number of data is a Size byte.

Besides, data contents shown in FIG. 15B are as follows:

P_CODE [3:0]: 4′ b0100. The present IC receives this code and stops theautomatic reading function.

PER [3:0]: sets a polling interval for MODE0, MODE1.

If it is determined that the operation is in the set state, theautomatic reading function determines that the index value is thesetting start address of the present IC and consecutively performs thesetting for the Size. If the setting for the Size is completed, it isdetermined again whether the operation is in the set state or the stopstate; if it is in the set state, the setting for the Size is performedfrom the index used as the setting start address. This operation isperformed until the stop is identified. If the stop is identified, theautomatic reading function is stopped. Thereafter, the polling for theMODE0, MODE1 is performed every time set as the polling interval; and ata time a pin-level change is confirmed, the operation is restarted.Besides, if MODE0, MODE1 are changed during the operation of theautomatic reading function, the setting is performed again immediatelyafter completion of the automatic reading operation.

Next, registers incorporated in the image process IC 100 are described.FIG. 16 is a register map of the image process IC 100. Here, access toEmpty- and Reserved-notation registers is prohibited.

FIG. 17 is a detailed table of a polarity set register POL. IDX_ADDRESSis 10h.

CKPOL sets a polarity of CAMCKI for CAMDI [7:0]. The set contents are asfollows:

0: a data change at a falling edge of CAMCKI, and data fetching at arising edge (see FIG. 18A).

1: a data change at a rising edge of CAMCKI, and data fetching at afalling edge (see FIG. 18B).

HSPOL sets a polarity of a horizontal synchronous signal (CAMHSI). AHIGH section contains valid data (LOW is a sink section). 0 is set intoHSPOL.

VSPOL sets a polarity of a vertical synchronous signal (CAMVSI). A HIGHsection contains valid data (LOW is a sink section). 0 is set intoVSPOL.

0 may be written into a bit of RESERVED.

FIG. 19 is a detailed table of a parameter update register PARAMSET.IDX_ADDRESS is 11h.

1 is written into PARAMSET_FR to apply a parameter update to a registerof a fog erasure block (IDX_ADDRESS: 30h to 37h). An internal parameteris updated at the head of a frame after the writing. This bit isautomatically cleared after the update.

1 is written into PARAM SET to update a parameter. An internal parameteris updated at the head of the frame after the writing. This bit isautomatically cleared after the update.

0 may be written into a bit of RESERVED.

FIG. 20 is a detailed table of a mode register MODE. IDX_ADDRESS is 12h.

The MODE [1:0] sets an image enhance operation mode of the present IC(see FIG. 21).

TH_TYPE sets a through-mode operation type. During a through-mode time,data and a synchronous signal are delayed by the same number of cyclesas in the image enhance mode and are output. 1 is set into TH_TYPE.

SUSP sets IO suspend modes. In a suspend mode, the respective signals ofCAMIO-7, CAMHSI, CAMVSI, CAMCKI are not transmitted to the inside of theIC.

The set contents are as follows:

0: suspend mode released

1: suspend mode

PD_OFF controls pull-down setting of AUTO, MODE0, and MODE1 of thepresent IC. The set contents are as follows:

0: An incorporated pull-down resistor is connected to each of AUTO,MODE0, and MODE1.

1: The incorporated pull-down resistor is separated form each of AUTO,MODE0, and MODE1.

DOUT_OFF controls digital output setting of the present IC. The setcontents are as follows:

0: Image data are output from a digital terminal.

1: CAMDO0-7, CAMHS0, CAMHS0, and CAMCK0 are output at a low level.

FR_OUT_SEL selects to output CAMHS0 which undergoes a timing adjustmentin the inside or FR_EN (IDX_ADDRESS: 30h bit [0]) from CAMHSI to aCAMHS0 terminal. The set contents are as follows:

0: CAMHS0 is output.

1: FR_EN is output.

FIG. 22 is a detailed table of an input interface format specificationregister YUVIFSET. IDX_ADDRESS is 13h.

YUV_XST [1:0] sets a delay from valid Hsync to valid data. 0 is set intoYUV_XST [1:0].

YUVORD [1:0] sets an input format of YCbCr. 10b (CbYCrY . . . ) may beset into YUVORD [1:0].

ITU601R selects a data range for a digital interface. Here, the settingother than the following is prohibited.

00b: Data input/output are performed in a full range.

11b: Data input/out are performed in an ITU601 range.

ITU656EN sets a digital interface for input and output. The set contentsare as follows:

0: Separate signals for Hsync, Vsync

1: ITU656 format

FIG. 22 is a detailed table of an output range conversion registerTRAM_LIM. IDX_ADDRESS is 49h.

TRAN_LIM applies a color space conversion (YUV→RGB→YUV conversion) to adigital output signal CAMDO7-0. If the color space conversion isperformed, an output chroma component is limited to a value that isrepresentable in an RGB space. The set contents are as follows:

0: Color space converted

1: Color space not converted

0 may be written into RESERVED.

FIG. 24 is a detailed table of a monitor X-direction pixel size setregister DXSIZE. IDX_ADDRESS is 14h and 15h. XSIZE [10:0] sets thenumber of pixels in the X direction of a utilized camera. An even numbermay be set. It is possible to set 320 to 1280.

FIG. 25 is a detailed table of a monitor Y-direction pixel size setregister DYSIZE. IDX_ADDRESS is 16h and 17h. YSIZE [10:0] sets thenumber of pixels in the Y direction of a utilized camera. It is possibleto set 240 to 960.

FIG. 26 is a detailed table of a foggy-image correction and imageenhance valid X-direction start position set register ICXST. IDX_ADDRESSis 18h and 19h. ICXST [9:0] sets an X-direction start position of avalid area for the foggy-image correction and the image enhancecorrection. An even number may be set. It is possible to set 0 to(XSIZE−ICXSIZE).

FIG. 27 is a detailed table of a foggy-image correction and imageenhance valid Y-direction start position set register ICYST. IDX_ADDRESSis 1Ah and 1Bh. ICYST [9:0] sets a Y-direction start position of a validarea for the foggy-image correction and the image enhance correction. Itis possible to set 0 to (YSIZE−ICYSIZE).

FIG. 28 is a detailed table of a foggy-image correction and imageenhance valid X-direction size set register ICXSIZE. IDX_ADDRESS is 1Chand 1Dh. ICXSIZE [10:0] sets an X-direction size (the number of pixels)of a valid area for the foggy-image correction and the image enhancecorrection. It is possible to set 320 to XSIZE.

FIG. 29 is a detailed table of a foggy-image correction and imageenhance valid Y-direction size set register ICYSIZE. IDX_ADDRESS is 1Ehand 1Fh. ICYSIZE [10:0] sets a Y-direction size (the number of pixels)of a valid area for the foggy-image correction and the image enhancecorrection. It is possible to set 240 to YSIZE.

FIG. 30 is a schematic view showing a valid area of the foggy-imagecorrection and the image enhance correction.

FIG. 31 is a detailed table of a pre-gamma set register PREGAMMA.IDX_ADDRESS is 20h. In the present IC, a pre-gamma filter isincorporated. This pre-gamma filter has 15 kinds of set values; the setvalues are selected by PREG [3:0]. PREG [3:0] is able to set 0 to 14;the smaller the number becomes, the larger the output luminance for alow luminance area becomes. Here, the setting of 15 into PREG [3:0] isprohibited.

FIG. 32 is a detailed table of a luminance correction strength setregister STRENGTH. IDX_ADDRESS is 21h. STR [6:0] sets the strength ofthe image enhance correction. STR [6:0] is able to set values of 0 to127.

FIG. 33 is a detailed table of a color difference correction strengthset register UV_STRENGTH. IDX_ADDRESS is 22h.

UV_STR [3:0] sets the correction strength of the image enhancecorrection of a color difference component. UV_STR [3:0] is able to set0 to 13; the larger the number becomes, the deeper the color becomes.The setting of 14, 15 is prohibited. Besides, in a case where thesetting is FR_AT=1, UV_STR_AT=1 and FR_EN=1 (IDX_ADDRESS: 30h FRCTL[4:3], [0]), the UV_STRENGTH for an image enhance correction block isnot set into the present register but into UV_STR_AT (IDX_ADDRESS: 07hUV_STR_AT [3:0]).

The larger the number in V_ENHANCE [3:0] becomes, the deeper the redcolor becomes. An enhancement by +about 3%×the set number is performed.

FIG. 34 is a detailed table of a noise curb set register NOISE_SUP.IDX_ADDRESS is 23h. NOISE_SUP [6:0] sets a noise curb value. It ispossible to set 10 to 127. If the number is increased, noise is curbed.The setting of 0 to 9 is prohibited.

FIG. 35 is a detailed table of an edge enhancement filter set registerEDG_CNT. IDX_ADDRESS is 24h.

EDG_ST [3:0] sets the strength of an edge enhancement filter. It ispossible to set 0 to 15. If the value is increased, the edge enhancementbecomes strong.

EDG_EN sets an enable state of the edge enhancement filter. The setcontents are as follows:

0: Disable

1: Enable

FIG. 36 is a detailed table of a response time set register RESP_SET.IDX_ADDRESS is 25h. RESP_SET sets a response time for an image enhanceeffect. 0 gives the fastest response time, while 15 gives the latestresponse time.

FIG. 37 is a detailed table of a post-filter enable register PELT_EN.IDX_ADDRESS is 26h. POFLT_EN sets an enable state of an output gammafilter. A characteristic set by an output gamma characteristic registeris used. The gamma filter works on an image after the image enhancecorrection process. The set contents are as follows:

0: Disabled

1: Enabled

FIG. 38 is a detailed table of output gamma characteristic registersPOELT0 to POFLT8. IDX_ADDRESS is 27h to 2F. POFLT0 to POFLT8 each set anoutput gamma characteristic.

FIG. 39 is a view showing an output gamma characteristic.

FIG. 40 is a detailed table of a foggy-image correction control registerFRCTL. IDX_ADDRESS is 30h.

FRCLK_EN supplies a clock to a foggy-image correction block. The setcontents are as follows:

0: Clock stopped

1: Clock supplied

FR_SLOP, during an automatic control time of the foggy-image correction(a time the setting is FR_AT=1), sets a slope time for a change in anS-curve range adjustment value (ACRVADJ register). A slope width alwayschanges in units of ±1 in accordance with the SCRVADJ value. The setcontents are as follows:

0: Slope control disabled

1: Slope control enabled

FR_AT sets a foggy-image correction method. During a time the automaticcontrol is selected, the present IC controls the FR_EN bit. The setcontents are as follows:

0: The foggy-image correction is manually set.

1: The foggy-image correction is automatically performed (the present ICperforms the control).

UV_STR_AT_EN, during a time the automatic control is in an on state andthe foggy-image correction function is valid, selects one of UV_STR(IDX_ADDRESS: 22h [3:0]) and UV_STR_AT (IDX_ADDRESS: 07h [3:0]) whichare to be valid as the UV_STR setting for an image enhance correctionfunction. The set contents are as follows:

0: The set value in UV_STR is always valid.

1: During a time the automatic control is in the on state and thefoggy-image correction function is valid, the set value in UV_STR_AT isvalid.

If 1 is written into REP_REQ, data of the next frame image are fetched.After 1 is written, it is possible to read data in 36h to 37h after thevalue becomes 0 (automatic clear). The set contents are as follows:

0: Not fetched (the data in 36h, 37h are invalid)

1: Fetching completed (the data in 36h, 37h are valid)

FR_TH performs through-operation control of the foggy-image correctionblock. A synchronous signal and data are delayed by the same number ofcycles as in the foggy-image correction process time and are output. 1may be set into FR_TH.

FR_EN performs operation control (during a time the setting is RF_AT=0)of the foggy-image correction process or operation confirmation (duringa time the setting is FR_AT=1) of the foggy-image correction process.The set contents are as follows. Here, the writing of 1 into the bit ofRESERVED is prohibited.

<during the time the setting is FR_AT=0>

0: The foggy-image correction disabled

1: The foggy-image correction enabled

<during the time the setting is FR_AT=1>

0: The foggy-image correction in stop

1: The foggy-image correction in operation

FIG. 41 is a detailed table of a foggy-image correction S-curve rangeadjustment register SCRVADJ. IDX_ADDRESS is 31h. SCRVADJ [3:0] performsan S-curve range adjustment of the foggy-image correction and sets thestrength of the foggy-image correction. FIG. 42 is a table showing arelationship between the set value in SCRVADJ and the strength of thefoggy-image correction.

FIG. 43 is a detailed table of a foggy-image correction γ-curve rangeadjustment register GCRVADJ. IDX_ADDRESS is 32h. GCRVADJ [3:0] performsa γ-curve range adjustment of the foggy-image correction and sets anoffset of a γ value. FIG. 44 is a table showing a relationship betweenthe set value in GCRVADJ and the offset of the γ value.

FIG. 45 is a detailed table of a histogram average luminance valueregister HAVGLUM. IDX_ADDRESS is 36h. HAVGLUM [3:0] is able to read ahistogram average value. A range of 0 to 255 is used.

FIG. 46 is a detailed table of a histogram standard dispersion valueregister HSTDVRC. IDX_ADDRESS is 37h. HSTDVRC [3:0] is able to read ahistogram dispersion value.

FIG. 47 is a detailed table of a between-fields low pass filter controlregister FR_LPF_CNT. IDX_ADDRESS is 3Eh. FR_LPF_EN makes a 5-tap lowpass filter valid for a parameter that is calculated in the inside ofthe foggy-image correction block. The set contents are as follows. Here,the writing of 1 into RESERVED is prohibited.

0: Low pass filter OFF

1: Low pass filter ON

FIG. 48 is a detailed table of between-fields LPF coefficient registersFR_LPF_COEF0 to FR_LPF_COEF4. IDX_ADDRESS is C2h to C6h. FR_LPF_COEF0[7:0] to FR_LPF_COEF4 [7:0] each set a coefficient of between-fields lowpass filters. Each filter coefficient has 1 bit of an integer portionand 7 bits of a decimal fraction portion, 8 bits in total and may be setat a binary number. Accordingly, in a case where the value is expressedwith a decimal number, the coefficient set value is as follows:

Coefficient=bit 7*20+bit 6*2−1+bit 5*2−2+bit 4*2−3+ . . . +bit 0*2−7

For example, in a case where 0.5 is set as a decimal number intoFR_LPF_COEF0, 40 h is set in the same register. Besides, the calculationof LPF is as follows:

P(n)′=P(n−2)*FR _(—) LPF _(—) COEF0+P(n−1)*

FR _(—) LPF _(—) COEF1+P(n)*FR _(—) LPF _(—) COEF2+

P(n+1)*FR _(—) LPF _(—) COEF3+P(n+2)*

FR _(—) LPF _(—) COEF4

Here, the setting has to be done in such a way that the sum of therespective coefficients always becomes 1.

FR _(—) LPF _(—) COEF0+FR _(—) LPF _(—) COEF1+FR _(—) LPF _(—) COEF2+FR_(—) LPF _(—) COEF3+FR _(—) LPF _(—) COEF4=80h

FIG. 49 is a detailed table of an automatic control UV_STR adjustmentregister UV_STR_AT. IDX_ADDRESS is 07h. If UV_STR_AT_EN (IDX_ADDRESS:30h [3])=1 and the foggy-image correction function is valid during atime the automatic control is in an on state, UV_STR AT [3:0] replacesthe UV_STR set value for the image enhance correction function with thepresent register value. Even during the time the automatic control is inthe on state, if the foggy-image correction function is invalid, thepresent register becomes invalid, and the image enhance correctionfunction follows the setting in UV_STR (IDX_ADDRESS: 22h [3:0]).

FIG. 50 is a detailed table of automatic control dispersion valuethreshold value set registers ACVRCTH1 to ACVRCTH3. IDX_ADDRESS is 08hto 0Ah. ACVRCTH1, 2, 3 [7:0], by means of ACVRCTH1, ACVRCTH2, andACVRCTH3, determine whether the input image is a foggy image or not foran input histogram dispersion value. Details are described later withreference to FIG. 53 and FIG. 54. Here, ACVRCTH1, ACVRCTH2, and ACVRCTH3should be so set as to meet the following relationship:

ACVRCTH1+4≦ACVRCTH2<ACVRCTH3

FIG. 51 is a detailed table of automatic control average value thresholdvalue set registers ACAVGTH1, ACAVGTH2. IDX_ADDRESS is 0Bh, 0Ch. In acase where the average luminance value of the histograms is larger thanACAVGTH1, ACAVGTH1, 2 [7:0] determine that the input image is a foggyimage and the correction function becomes valid. After the foggy-imagecorrection function becomes valid, if the average luminance value of thehistograms becomes smaller than ACAVGTH2, the foggy-image correctionfunction is made invalid. Details are described later with reference toFIG. 53 and FIG. 54. Here, ACAVGTH1 and ACAVGTH2 should be so set as tomeet the following relationship. Here, in a case whereACAVGTH1=ACAVGTH2, the hysteresis function for the input-image luminancevalue determination is turned off.

ACAVGTH1≧ACAVGTH2

FIG. 52 is a detailed table of automatic control S-curve correctionregion set registers ACSCV11 to ACSCV13. IDX_ADDRESS is 0Dh to 0Fh.

ACSCV_ULIM [3:0], ACSCV_MH [3:0], ACSCV_MM [3:0], ACSCV_ML [3:0] andACSCV_LLIM [3:0], during the automatic control time, performs thesetting of a foggy-image correction amount: S-curve range adjustment forthe input dispersion value. The strength of the set value is the same asthe SCRVADJ register (IDX_ADDRESS: 31h). Details are described laterwith reference to FIG. 53 and FIG. 54. ACSCV_ULIM, ACSCV_MH, ACSCV_MM,ACSCV_ML and ACSCV_LLIM should be so set as to meet the followingrelationships:

ACSCV _(—) ULIM>ACSCV _(—) LLIM

ACSCV _(—) ULIM≧ACSCV _(—) MH≧ACSCV _(—) MM≧ACSCV _(—) ML≧ACSCV _(—)LLIM

FR_SLOP_CNT [1:0], during a time the slope setting (FR_SLOP) is valid inthe automatic control, sets a slope time. The set contents are asfollows:

00b: Updated for every field

01b: Updated for every 16 fields

10b: Updated for every 32 fields

11b: Updated for every 64 fields

FIG. 53 is a flow chart for describing the foggy-image correctionautomatic control; FIG. 54 is a view showing a schema of a foggy-imagecorrection automatic control algorithm. Here, because FIG. 53 and FIG.54 respectively correspond to the above FIG. 4 and FIG. 6A, hereinafter,only an overview of them is described.

In the automatic control of the foggy-image correction, an S-curve rangeadjustment is performed in the following sequence.

(1) Comparison of the Input Luminance and the ACVRCTH1 Register Value

First, in a step S201, the average luminance value of the input imageand the ACVRCTH1 register value are compared with each other. If theaverage luminance value of the input image is higher, the flow moves onto an S-curve range adjustment determination state (step S202). In theluminance determination, to prevent ON/OFF near the ACVRCTH1 registervalue from occurring, it is possible to set a hysteresis width. Thefoggy-image correction is turned on if the input luminance is largerthan the ACVRCTH1 register value, and is turned off if the inputluminance is smaller than the ACVRCTH1 register value,

(2) S-Curve Range Adjustment

In the S-curve range adjustment, a dispersion value of the input imageis determined; and the SCRVADJ register value is calculated inaccordance with the dispersion value. The set range specification forthe S-curve range adjustment is performed with ACSCV_ULIM, ACSCV_MH,ACSCV_MM, ACSCV_ML and ACSCV_LLIM. The standard dispersion specificationis performed with ACVRCTH1, ACVRCTH2 and ACVRCTH3; and the differencebetween ACVRCTH1 and ACVRCTH2 is equally divided into four sections. Forexample, if the input dispersion value has the same value as theACVRCTH1 value, the SCRVADJ register value is set at the ACSCV_ULIMvalue. Like in the input luminance determination time, in the S-curverange adjustment as well, to prevent a deviation at the set boundary, asshown in FIG. 54, a hysteresis is present. In a case where thedispersion value of the input image gradually becomes large, the S-curverange adjustment is performed along a route represented by a broken linein FIG. 54; if the dispersion value of the input image becomes largerthan ACVRCTH3, the foggy-image correction function is turned off. Afterbeing turned off, if the dispersion value of the input image becomeslarger than ACVRCTH2, the foggy-image correction function is turned onto perform the S-curve range adjustment in accordance with thedispersion value.

Thereafter, the above (1) and (2) are repeated to control thefoggy-image correction ON/OFF and the S-curve range adjustment.

FIG. 55 is a detailed table of a TV encoder reset register PWD.IDX_ADDRESS is 41h.

DAC_POW turns on/off a DAC operation in the present IC. The set contentsare as follows:

0: DAC operation ON

1: DAC operation OFF

LOGIC_POW performs clock on/off control of a TV-Encoder block. The setcontents are as follows:

0: The internal clock is turned off

1: The internal clock is turned on.

FIG. 56 is a detailed table of a TV encoder display mode register DISP.IDX_ADDRESS is 43h.

LEVEL determines whether an input data range of the TV encoderincorporated in the present IC is a full range or an ITU_R 601 range. Inaccordance with the set value in ITU601R (IDX_ADDRESS: 13h YUVIFSET[3:2]), the register setting may be performed. The set contents are asfollows:

0: In a case of the setting ITU601R=2′ b00, the setting LEVEL=0 shouldbe performed.

1: In a case of the setting ITU601R=2′ b11, the setting LEVEL=1 shouldbe performed.

DISPO selects an operation mode of the TV encoder in the inside of thepresent IC. In a square pixel mode, 640 pixels in the horizontaldirection is increased to 720 pixels. In a case other than 27 MHz of theinput clock, 0 should be written into this bit. The set contents are asfollows:

0: Equalization pixel mode

1: Square pixel mode

FIG. 57 is a detailed table of a TV encoder video mode register VIDEO.IDX_ADDRESS is 45h.

NTPAL selects a video output mode of the TV encoder incorporated in thepresent IC. The set contents are as follows:

0: NTSC

1: PAL

Q_FSC selects a clock operation mode of the TV encoder in the inside ofthe present IC. A clock for the selected mode may be input. The setcontents are as follows:

0: 27 MHz clock operation

1: 4 fsc clock operation (input clock is 8 fsc)

PAL28 is turned on (1) in a case where the clock operation mode of theTV encoder in the inside of the present IC is PAL and 28.375 MHz isused. The set contents are as follows:

0: In a case where 28.375 MHz clock operation is not performed in PAL

1: In a case where 28.375 MHz clock operation is performed in PAL

510H selects an operation mode of the TV encoder in the inside of thepresent IC. The set contents are as follows:

0: Usual operation

1: 510H mode

C_OFF turns off output of Cb, Cr and a color burst signal. The setcontents are as follows. Here, 0 should be written into RESERVED.

0: Usual operation (Cb, Cr and the color burst signal are summed andoutput)

1: Cb, Cr and the color burst signal are output without being summed.

FIG. 58 is a list showing usable setting of the TV encoder video moderegister VIDEO. Setting other than the setting shown in this figure isprohibited.

FIG. 59 is a detailed table of a TV encoder video mode register CVBS.IDX_ADDRESS is 46h.

CVBS_OUT selectively turns on/off video output (DAC) from the TV encoderincorporated in the present IC. The set contents are as follows:

0: The DAC output is not performed.

1: CVBS (composite video signal) is output as the DAC output.

IMAGE_OUT [1:0] selects video output data of the TV encoder in theinside of the present IC. The set contents are as follows:

00b: RESERVED

01b: A color selected by a BGCOL register is output over the entirescreen area.

10b: RESERVED

11b: An image is output. Besides, the color selected by BGCOL is outputto a background area.

FIG. 60 is a detailed table of the background color register BGCOL.IDX_ADDRESS is 47h. BGCOL [3:0] selects a background color in the videooutput (DAC) from the TV encoder incorporated in the present IC. The setcontents are as follows. Here, setting other than the following settingis prohibited.

00 (hex): BLUE background color [Default]

01 (hex): BLACK background color

02 (hex): RED background color

03 (hex): GREEN background color

04 (hex): YELLOW background color

05 (hex): CYAN background color

06 (hex): MAGENTA background color

07 (hex): GRAY background color

08 (hex): WHITE background color

FIG. 61 is a detailed table of a TV encoder color bar test registerCOLBAR. IDX_ADDRESS is 48h. COLBAR specifies the output from the TVencoder incorporated in the present IC as a color bar output. The setcontents are as follows:

0: The input data of the present IC is output.

1: A color bar is forcibly output.

FIG. 62 is a detailed table of a TV encoder setup register SETUP.IDX_ADDRESS is 55h.

BURST_LVL is able to adjust levels of a burst signal and a color carrierwave. The set contents are as follows:

0: Default setting

1: The levels of the burst signal and the color carrier wave areamplified from the 0 setting by about 0.8 IRE.

SETUP performs setting in accordance with NTSC or PAL. The set contentsare as follows:

0: In a case of NTSC, 0 should be set.

1: In a case of PAL. 1 should be set.

FIG. 63 is a detailed table of a TV encoder setup2 register SETUP2.IDX_ADDRESS is 50h. SETUP2 sets an operation mode of the TV encoder.Here, setting other than the following setting is prohibited.

000b: In a case other than the 510H mode, 000b should be set.

011b: In a case of the 510H mode, 011b should be set.

FIG. 64 is a detailed table of TV encoder gamma correction registersGM_A0 to GM_A2, GM_X0 to GM_X3, and GM_Y0 to GM_Y3. IDX_ADDRESS is D0hto DAh.

FIG. 65 is a view showing a gamma correction curve. The setting of thegamma correction curve is decided by four point coordinates (x0, y0),(x1, y1), (x2, y2), and (x3, y3) and three inclination coefficients a0,a1, and a2 that are shown in FIG. 65. In bit values GM_A0, GM_A1, andGM_A2 that correspond to the three inclination coefficients a0, a1, anda2, the four leftmost bits indicate an integer and the four rightmostbits indicate a decimal fraction.

A solid line shown in FIG. 65 represents a gamma curve that isapproximated by the following conditions:

(1) When X<x0,

Y=y0

2) When x0≦X<x1,

Y=a0*(X−x0)+y0

3) When x1≦x<x2,

Y=a1*(X−x1)+y1

4) When x2≦X<x3,

Y=a2*(X−x2)+y2

5) When x3≦X,

Y=y3

FIG. 66 is a table showing setting examples of the gamma correctionregisters GM_A0 to GM_A2, GM_X0 to GM_X3, and GM_Y0 to GM_Y3. An outputvalue 16 (10h) corresponds to 0IRE, and an output value 235 (EBh)corresponds to 100IRE. In a case of the setting shown in FIG. 66, theoutput is limited to the maximum value 235 (EBh), and a white level ofthe TV output is limited to 100IRE.

FIG. 67 is a detailed table of an input valid start pixel offset setregister OFS. IDX_ADDRESS is E0h, E1h. H_POS sets a display offsetduring a TV encoder output time, while this register sets a valid datastart pixel from HSYNC at the input.

FIG. 68 is a detailed table of a TV encoder valid data width setregister WID_VD. IDX_ADDRESS is E2h, E3h. This register sets the numberof valid pixels in a horizontal line. The initial value is 320 pixel.The set value should be an even number. Besides, the set range isbetween 100 pixels to 896 pixels. The set contents are as follows. Here,the WID_VD register should set a number that is a multiple of 4.

FIG. 69 is a detailed table of a TV encoder valid line width setregister HT_VD. IDX_ADDRESS is E4h. This register sets the number ofvalid lines in a field. The initial value is 240. The number of linesthat is output to a TV in actual use is a value that is obtained byattaching an offset of +64 to the HT_VD register value. The range ofvalues that are able to be set into the register is from 100 to 254lines. Accordingly, the range of set lines displayable on a TV is from164 lines to 318 lines. The set contents are as follows:

FIG. 70 is a detailed table of a TV encoder horizontal display positionoffset register H_POS. IDX_ADDRESS is E5h. This register sets an offsetof a horizontal display position in a line. The initial value is 0. Therange that is able to be set is 0 to 504 pixels. The offset of adisplayed horizontal position is expressed by the following formula:

Offset value of a displayed horizontal position: H _(—) POS [7:0]×2[Pixel]

The set contents of the TV encoder horizontal display position offsetregister H_POS are as follows:

FIG. 71 is a detailed table of a TV encoder vertical display positionoffset register V_POS. IDX_ADDRESS is E6h. This register sets an offsetof a vertical display position in a field. The initial value is 0. Therange that is able to be set is 0 to 120 lines. The offset of adisplayed vertical position is expressed by the following formula:

Offset value of a displayed vertical position: V _(—) POS [7:0]+4 (linein a field)

-   -   (in a case of NTSC)

Offset value of a displayed vertical position: V _(—) POS [7:0]+23 (linein a field)

-   -   (in a case of PAL)

The set contents in the TV encoder vertical display position offsetregister V_POS are as follows:

FIG. 72 is a detailed table of an input valid start line offset setregister V_OFS. IDX_ADDRESS is E7h. V_POS sets a display offset during aTV encoder output time, while this register sets a valid data start linefrom VSYNC at the input.

FIG. 73 is a schematic view showing set contents of a display positionchange register.

FIG. 74 is a detailed table of an SPI control register SPICNT.IDX_ADDRESS is F0h. This register is a register that performs the SPIcontrol. REG_WPB sets an output level of a WPB terminal (output value isdirectly reflected). REG_SCEB sets an output level of a SCEB terminal(output value is directly reflected). REG SCK sets an output level of aSCK terminal before SPI operation (output value is directly reflected).REG_SDO sets an output level of a SDO terminal before the SPI operation(output value is directly reflected). SWRITE is a WDATA output enablebit for the SDO terminal during the SPI operation. If SWRITE is set at0, the value of a REG_SDO bit continues to be output. 1 is read fromSBUSY during the SPI operation; and when the SPI operation is completed,0 is read. SACT is only for writing: only 0 is read. Besides, by writing1 into SACT, clocks for 8-bit data are generated to execute the SPIoperation.

FIG. 75 is a detailed table of an SPI operation clock frequency divisionregister SPIDIV. IDX_ADDRESS is F1h. This register sets a frequencydivision ratio for the CAMCKI clock to decide a frequency of an SCKterminal clock during a time of the SPI operation. The frequency isdecided by the following formula:

SCK frequency: 1/(2̂SPIPREDIV [2:0])/(SPIDIV [4:0]+1)

Initial value 35.5 MHz/(2̂4*(22+1))=96.5 kHz; when a CAMCKI frequency is35.5 MHz.

FIG. 76 is a detailed table of an SPI write data set register SPIWDATA.IDX_ADDRESS is F2h. This register sets output data to the SDO terminalduring the SPI operation.

FIG. 77 is a detailed table of an SPI read data register SPIRDATA.IDX_ADDRESS is F3h. This register stores input data from the SDIterminal during the SPI operation.

FIG. 78 is a detailed table of an SPI EEPROM read address set register0: SPIADR0L. IDX_ADDRESS is F4h. This register sets the 8 rightmost bitsof the EEPROM address during a time EEPROM automatic reading is executedwhen the MODE0, MODE1 terminals have 0, 0, respectively.

FIG. 79 is a detailed table of an SPI EEPROM read address set register1: SPIADR1L. IDX_ADDRESS is F5h. This register sets the 8 rightmost bitsof the EEPROM address during the time the EEPROM automatic reading isexecuted when the MODE0, MODE1 terminals have 1, 0, respectively.

FIG. 80 is a detailed table of an SPI EEPROM read address set register2: SPIADR2L. IDX_ADDRESS is F6h. This register sets the 8 rightmost bitsof the EEPROM address during the time the EEPROM automatic reading isexecuted when the MODE0, MODE1 terminals have 0, 1, respectively.

FIG. 81 is a detailed table of an SPI EEPROM read address set register3: SPIADR3L. IDX_ADDRESS is F7h. This register sets the 8 rightmost bitsof the EEPROM address during the time the EEPROM automatic reading isexecuted when the MODE0, MODE1 terminals have 1, 1, respectively.

FIG. 82 is a detailed table of an SPI EEPROM read address bit 8 setregister: SPIADR1_H. IDX_ADDRESS is F8h. The set contents in thisregister are as follows:

SPIADR0H: The bit 8 of SPIADR0 is set with an EEPROM read address.

SPIADR1H: The bit 8 of SPIADR1 is set with an EEPROM read address.

SPIADR2H: The bit 8 of SPIADR2 is set with an EEPROM read address.

SPIADR3H: The bit 8 of SPIADR3 is set with an EEPROM read address.

FIG. 83 is a detailed table of an initialization register SRST.IDX_ADDRESS is FFh. This register is a software reset register. Bywriting 1, a related block is reset. Only writing 1 is valid. Accessshould not be performed for 100 ns after a software reset. After ahardware reset, it is unnecessary to perform the software reset. Thecontents in this register are as follows:

SRST_AIE: By writing 1, a reset of an image enhance block is performed.By writing 0, the reset is released.

SRST_TVE: By writing 1, a reset of a TV encoder block is performed. Bywriting 0, the reset is released.

SRST_REG: By writing 1, a reset of a register is performed. The registervalue becomes the initial value. The reset is automatically released.

SRST_FOG: By writing 1, a reset of a foggy-image correction block isperformed. By writing 0, the reset is released.

FIG. 84 is a connection diagram showing a system example that uses theimage process IC 100. As shown in this figure, a camera module, acontroller, an EEPROM, an image processor and the like are externallyconnected to the image process IC 100.

Next, a method for curbing a color imbalance and a luminance dynamicrange shortage after the image correction process is performed isdescribed in detail.

FIG. 85A is a block diagram showing an example of an image correctionprocess device that includes a first image correction process portiononly.

A first image correction process portion 601 applies a first imagecorrection process to the digital input image data to generate digitaloutput image data. Here, the first image correction process refers to animage correction process which is based on a luminance histogram, andbesides an original purpose, is likely to bring a color-componentimbalance or a luminance dynamic range shortage as a byproduct, and towhich the above foggy-image correction process, for example,corresponds.

However, in the above structure in which only the first image correctionprocess is performed, depending on the process method and theinput-image data contents, besides the original purpose (e.g., removalof fog and haze), a color-component imbalance or a luminance dynamicrange shortage occurs as a byproduct, so that there is a risk that anunnatural output image is generated.

FIG. 85B is a block diagram showing an example of an image correctionprocess device that includes a second image correction process portionon a stage after the first image correction process portion.

The first image correction process portion 601 applies the first imagecorrection process to the digital input image data to generate digitalintermediate image data. Here, the first image correction process refersto an image correction process which as described above, is based on aluminance histogram, and besides an original purpose, is likely to bringa color-component imbalance or a luminance dynamic range shortage as abyproduct, and to which the above foggy-image correction process, forexample, corresponds. In other words, the first image correction processportion 601 represented in FIG. 85B corresponds to the first imagecorrection process portion 201 represented in the above FIG. 7. However,the contents of the first image correction process are not limited tothe foggy-image correction process.

A second image correction process portion 602 applies a second imagecorrection process to the digital intermediate image data input from thefirst image correction process portion 601 to generate digital outputimage data. Here, the second image correction process refers to an imagecorrection process which resolves a color-component imbalance and aluminance dynamic range shortage that are caused by the first imagecorrection process, and to which for example, the above image enhanceprocess (luminance dynamic range correction process that includes acolor-space correction process such as saturation curbing and the like)corresponds. In other words, the second image correction process portion602 represented in FIG. 85B corresponds to the second image correctionprocess portion 202 represented in the above FIG. 7. However, thecontents of the second image correction process are not limited to theimage enhance process.

As described above, the second image correction process, which resolvesa color-component imbalance and a luminance dynamic range shortage, isapplied to the intermediate image data obtained by the first imagecorrection process, so that it becomes possible to improve thevisibility of the finally obtained output image.

Next, a method for curbing a flicker after the foggy-image correctionprocess is performed is described in detail.

In the above foggy-image correction process, luminance histogramdistribution is prepared; and based on the maximum value, the minimumvalue, the central value, the standard deviation value and the like ofthe distribution, optimization (removal of fog and haze) of theluminance histogram is performed. As a result of this, in almost allscenes of still images and dynamic images, it is possible to obtain agood evaluation result.

However, when applying the foggy-image correction process to a dynamicimage, it becomes a problem that because of influence of disturbance andthe like, the input image data are uneven in every one frame in aninvisible range. For example, as shown in FIG. 86, it seems at a glancethat there is no deviation in the luminance histogram distributionbetween an N-th frame and an (N+1)-th frame; however, if the respectiveregions near the maximum values of the frames are enlarged, it isunderstood that there is a minute deviation in the luminance valuedistribution.

If the foggy-image correction process is applied to such input imagedata, the foggy-image correction amount changes for every frame, so thatthere is a risk that the above minute deviation is enhanced by thefoggy-image correction process; in some cases, as shown in FIG. 87, anapparent difference in every frame appears over the entire luminancehistogram distribution (especially, the luminance peak value) after thefoggy-image correction process, so that there is a risk that screenunevenness (flicker) occurs.

It is conceivable that the above problems are caused because thefoggy-image correction process is performed by means of the entireluminance histogram range (that is, all the luminance range thatincludes the maximum value and its nearby region where a minute changeis likely to occur; and the minimum value and its nearby region where aminute change is likely to occur).

Accordingly, to solve the above problems, in the image correction deviceaccording to the present invention, the structure is employed, in whichthe first image correction process portion (to which the first imagecorrection process portion 201 represented in FIG. 7 and the first imagecorrection process portion 601 represented in FIG. 85B correspond) isstructured in such a way that a valid luminance range of the luminancehistogram that is referred to during a time of calculating thecorrection coefficient is variably set.

FIG. 88 is a block diagram showing a first structural example of thefirst image correction process portion. The first image correctionprocess portion in the present structural example includes: a luminancehistogram generation portion 701; a luminance histogram rangespecification portion 702; and a foggy-image correction portion 703.Here, a sign Y in the figure represents a luminance component; and signsU, V represent color components. Besides, signs R, G, and B in thefigure represent a red component, a green component, and a bluecomponent, respectively.

The luminance histogram generation portion 701, based on the luminancecomponent Y of the input image data, generates the luminance histogramdistribution and outputs this to the luminance histogram rangespecification portion 702.

The luminance histogram range specification portion 702 sets a validrange of the luminance histogram distribution generated by the luminancehistogram generation portion 701. For example, the luminance histogramrange specification portion 702, as shown in FIG. 89, sets the maximumvalue and the minimum value of the luminance histogram distribution intoregisters in such a way that during a time of calculation by thefoggy-image correction portion 703, a predetermined luminance range froman upper limit value (255) of the luminance histogram and apredetermined luminance range from a lower limit value (0) of theluminance histogram are considered invalid and neglected.

The foggy-image correction portion 703, based on the luminance histogramdistribution in the valid range set by the luminance histogram rangespecification portion 702, calculates a calculation coefficient(correction coefficient) for the foggy-image correction process; anduses this to apply the foggy-image correction process to the input imagedata. Here, in the structural example in FIG. 88, the input image dataconverted from a YUV form into an RGB form are input into thefoggy-image correction portion 703.

As described above, according to the structure in which when calculatingthe calculation coefficient (correction coefficient) for the foggy-imagecorrection process, the region near the maximum value of the luminancehistogram and the region near the minimum value of the luminancehistogram where a minute change is likely to occur are consideredinvalid, the risk that a minute deviation in the input image data isenhanced by the foggy-image correction process is reduced, so that itbecomes possible to curb unevenness (flicker) on the screen.

Here, the valid range of the luminance histogram distribution islimited, so that in the output image after the foggy-image correctionprocess, under-exposure and over-exposure are likely to occur more orless; however, because these are traded off for a measure against theflicker, the valid range of the luminance histogram distribution may beadjusted if necessary.

However, even if the valid range of the luminance histogram distributionis limited, there is a case where more or less flicker is likely toremain. Accordingly, as a measure against the flicker, the followingstill another structure is effective.

FIG. 90 is a block diagram showing a second structural example of thefirst image correction process portion. The first image correctionprocess portion in the present structural example, besides the firststructural example shown in FIG. 88, includes a low pass filter portion704 on a stage after the luminance histogram range specification portion702.

The low pass filter portion 704 is a between-frames filter(between-fields filter) that when deciding a correction coefficient fora frame (field), uses the correction coefficient for the frame and acorrection coefficient for at least one frame that is input before orafter the frame, thereby applying a low pass filter process to thecorrection coefficient for the frame.

The low pass filter portion 704 has a function that applies a 5-tap lowpass filter process to a calculation parameter (fog correctionparameter) in the inside of the foggy-image correction block of the IC,thereby cutting a high-frequency component (sharp change) of thecalculation parameter.

According to this function, even if a scene of a taken image rapidlychanges and because of this, the calculation parameter for thefoggy-image correction rapidly changes, the parameter is not immediatelyreflected onto the corrected image, so that the corrected image slowlychanges over 5 fields. According to this, even in a scene where theinput image changes for every field like a flicker and the calculationparameter for the fog correction changes for every field, thecalculation parameter is smoothed by the low pass filter process portion704, so that it is possible to curb the flicker.

The filtering process for the calculation parameter in the low passfilter portion 704 is executed in units of a field. By means of twofields before and after a calculation target field, the low pass filterprocess is performed.

FIG. 91A and FIG. 91B both are schematic views for describing the lowpass filter process. Here, FIG. 91A shows a way of calculating acalculation parameter for a field 2; FIG. 91B shows a way of calculatinga calculation parameter for a field 3.

Meanings of the coefficients shown in FIG. 91A and FIG. 91B aredescribed. Because the low pass filter process is 5-tap, there are 5coefficient set registers and fields corresponding to the respectivecoefficients are as follows:

-   -   FR_LPF_COEF0: Coefficient setting for a parameter for a field        (N−2)    -   FR_LPF_COEF1: Coefficient setting for a parameter for a field        (N−1)    -   FR_LPF_COEF2: Coefficient setting for a parameter for a field N        (field as a calculation target)    -   FR_LPF_COEF3: Coefficient setting for a parameter for a field        (N+1)    -   FR_LPF_COEF4: Coefficient setting for a parameter for a field        (N+2)

All the coefficient registers are composed of 8 bits: an integer portionmay be expressed by 1 bit (MSB), while a decimal fraction portion may beexpressed by 7 bits. Accordingly, the coefficient values correspondingto the respective register values (hexadecimal notation) are as follows:

80h:1.0000000

40h:0.5000000

20h:0.2500000

10h:0.1250000

08h:0.0625000

04h:0.0312500

02h:0.0156250

01h:0.0078125

For example, a coefficient value 0.75 is expressed 60h in thehexadecimal notation. Here, the setting needs to be performed in such away that the set values in the respective coefficient registers are 00hto 80h, and the sum of the five register values is 80h. This is becauseit is necessary to set the sum of the respective coefficients at 1.00.

Next, the setting of the above coefficients is described. As for thestrength of the low pass filter process, as the coefficient for thecalculation target field, that is, the set value in FR_LPF_COEF2 becomeslarger, the strength becomes weaker, while as the set value inFR_LPF_COEF2 becomes smaller (as the coefficient values for the fieldsbefore and after the field become larger), the strength becomesstronger.

For example, in a case where the following setting is performed as thesetting for the low pass filter process, the parameter for the field 2becomes a parameter as it is after the low pass filter process, which ineffect brings the same operation as the operation in a case where thelow pass filter function is turned off.

FR_LPF_COEF0: 00h

FR_LPF_COEF1: 00h

FR_LPF_COEF2: 80h

FR_LPF_COEF3: 00h

FR_LPF_COEF4: 00h

In contrast, as the parameter value in FR_LPF_COEF2 becomes smaller, thestrength of the low pass filter becomes stronger. A setting example isas follows:

<Low Pass Filter: Strong Setting>

FR_LPF_COEF0: 10h

FR_LPF_COEF1: 20h

FR_LPF_COEF2: 20h

FR_LPF_COEF3: 20h

FR_LPF_COEF4: 10h

<Low Pass Filter: Weak Setting>

FR_LPF_COEF0: 08h

FR_LPF_COEF1: 18h

FR_LPF_COEF2: 40h

FR_LPF_COEF3: 18h

FR_LPF_COEF4: 08h

Here, the above low pass filter process serves as a trade-off betweenthe flicker curbing and the improvement of dynamic-image following.Accordingly, it is important to design the optimum low pass filter forevery application changing the number of taps and considering aninfluence on not only a scene where a flicker occurs but also otherscenes.

Next, an electronic device (a set or a system is included) thatincorporates the image correction IC according to the present inventionis described.

As shown in the above FIG. 7, the image process IC 100 according to thepresent invention integrates: a first external terminal CAMDI [7:0] intowhich the digital input image data are input from outside of the IC; theimage correction process circuit 200 that applies the predeterminedimage correction process to the digital input image data to generate thedigital output image data; a second external terminal CAMDO [7:0] fromwhich the digital output image data are output to the outside of the IC;the encoder circuit 300 that converts the digital output image data intothe output image data in the analog composite video form; and a thirdexternal terminal VOUT from which the output image data in the analogcomposite video form are output to the outside of the IC.

If such image process IC 100 is incorporated into an existing electronicdevice, without requiring a dramatic design modification, it becomespossible to add the foggy-image correction function and the TV encoderfunction.

FIG. 92A and FIG. 92B each are views showing structural examples ofelectronic devices (indoor/outdoor monitor cameras, network cameras (IPcameras), Web cameras, vehicle cameras, intercoms and the like) thatincorporate the image process IC according to the present invention.

Electronic devices 800 in both structural examples include: a camera801; an AFE [Analog Front End] 802; and a camera DSP 803; and besidesthem, incorporates an image process IC 804 according to the presentinvention.

Here, FIG. 92A shows a structure in which the image process IC 804 iscontrolled by a program stored in an EEPROM 805. In a case of thepresent structural example, the camera 801 and the AFE 802 arecontrolled via the camera DSP 803 that is connected to a general-purposeinterface (GPIO). On the other hand, FIG. 92B shows a structure in whichthe image process IC 804 is controlled by an instruction from amicrocomputer 806 that is connected to the general-purpose interface(GPIO). In the case of the present structure, the camera 801 and the AFE802 are also controlled via the microcomputer 806.

As described above, according to the electronic device 800 thatincorporates the image process IC 804 according to the presentinvention, without applying a dramatic design modification to an exitingcircuit, it becomes possible to apply a suitable image correctionprocess (fog erasure process) to the input image data and to perform theanalog composite video output.

Here, besides the above embodiments, it is possible to make variousmodifications to the structure of the present invention withoutdeparting from the spirit of the present invention. In other words, itshould be understood that the embodiments are examples in all respectsand are not limiting; the technical scope of the present invention isnot indicated by the above description of the embodiments but by theclaims; and all modifications within the scope of the claims and themeaning equivalent to the claims are covered.

INDUSTRIAL APPLICABILITY

The present invention is a useful technology for improving visibility ofan output image in the fields of: an image correction process circuitwhich applies various image correction processes to an input image togenerate a desired output image; and a semiconductor device whichintegrates the image correction process circuit.

Besides, the image correction device according to the present inventionis generally applicable to electronic devices (indoor/outdoor monitorcameras, security cameras, network cameras (IP cameras), Web cameras,vehicle cameras, drive recorders, intercoms and the like) that processimage data.

REFERENCE SIGNS LIST

-   -   10 image process IC (semiconductor device)    -   11 foggy-image correction portion    -   12 luminance histogram calculation portion    -   13 correction control portion    -   131 first comparison portion    -   132 second comparison portion    -   133 determination portion    -   14 register    -   20 image source (image taking device and the like)    -   30 display device (liquid crystal display and the like)    -   40 microcomputer    -   100 image process IC (semiconductor device)    -   200 image correction process circuit    -   201 first image correction process portion (foggy-image        correction portion)    -   202 second image correction process portion    -   202 a color correction portion    -   202 b luminance determination portion    -   202 c image enhance portion    -   202 d calculation process portion    -   300 encoder circuit    -   301 memory controller    -   302 line memory    -   303 complement portion    -   304 gamma correction portion    -   305 low pass filter portion    -   306 trap filter portion    -   307, 308 low pass filter portions    -   309 to 312 calculation process portions    -   313 digital/analog conversion portion    -   314 timing signal generation portion    -   315 sub-carrier signal generation portion    -   316 color bar signal generation portion    -   400 first serial interface circuit (I2C)    -   500 second serial interface circuit (SPI)    -   601 first image correction process portion    -   602 second image correction process portion    -   701 luminance histogram generation portion    -   702 luminance histogram range specification portion    -   703 foggy-image correction portion    -   704 low pass filter portion    -   800 electronic device    -   801 camera    -   802 AFE    -   803 camera DSP    -   804 image process IC    -   805 EEPROM    -   806 microcomputer

1. An image correction process circuit, comprising: an image correctionportion that applies a predetermined image correction process to aninput image to generate an output image; a calculation portion thatobtains a luminance histogram for every one field of the input image andcalculates two values or all three values of an average luminance value,a standard deviation value and an intermediate value; and a correctioncontrol portion that based on two values or all the three values of theaverage luminance value, the standard deviation value and theintermediate value of the luminance histogram which are calculated bythe calculation portion, determines whether the image correction processis necessary or not for the input image and a correction amount for theimage correction process, and performs control of the image correctionportion.
 2. The image correction process circuit according to claim 1,wherein the image correction portion applies a foggy-image correctionprocess to the input image; and the correction control portion, based onthe average luminance value and the standard deviation value of theluminance histogram, determines whether the foggy-image correctionprocess is necessary or not for the input image and the correctionamount for the image correction process.
 3. The image correction processcircuit according to claim 2, wherein the correction control portiondetermines that the foggy-image correction process is necessary when theaverage luminance value of the luminance histogram is larger than afirst threshold value and the standard deviation value of the luminancehistogram is smaller than a second threshold value.
 4. The imagecorrection process circuit according to claim 3, wherein when thecorrection control portion determines that the foggy-image correctionprocess is necessary, the correction control portion sets a largercorrection amount for the foggy-image correction process in a stepwiseway or a continuous way when the standard deviation value of theluminance histogram is smaller.
 5. The image correction process circuitaccording to claim 3, wherein a hysteresis width is set in at least oneof the first threshold value and the second threshold value.
 6. Theimage correction process circuit according to claim 1, furthercomprising a register for externally setting various parameters that arereferred to by the correction control portion when the correctioncontrol portion determines whether the image correction process isnecessary or not for the input image and the correction amount.
 7. Asemiconductor device that integrates the image correction processcircuit according to claim
 1. 8. An image correction process device,integrating and comprising: a first external terminal into which digitalinput image data are input from outside of the device; an imagecorrection process circuit that applies a predetermined image correctionprocess to the digital input image data to generate digital output imagedata; a second external terminal from which the digital output imagedata are output to the outside of the device; an encoder circuit thatconverts the digital output image into output image data in an analogcomposite video form; and a third external terminal from which theoutput image data in the analog composite video form are output to theoutside of the device.
 9. The image correction process device accordingto claim 8, wherein the image correction process circuit includes: afirst image correction process portion that applies a first imagecorrection process, which is an image correction process based on aluminance histogram, and besides an original purpose, is likely to bringa color-component imbalance or a luminance dynamic range shortage, tothe digital input image data to generate digital intermediate imagedata; and a second image correction process portion that applies asecond image correction process, which eliminates a color-componentimbalance or a luminance dynamic range shortage caused by the firstimage correction process, to the digital intermediate image data,thereby generating the digital output image data.
 10. The imagecorrection process device according to claim 9, wherein the first imagecorrection process is a foggy-image correction process, and the secondimage correction process is a color correction process or a luminancedynamic range correction process.
 11. The image correction processdevice according to claim 9, wherein in the first image correctionprocess portion, a valid luminance range of the luminance histogram,which is referred to during a time of calculating a correctioncoefficient, is variably set.
 12. The image correction process deviceaccording to claim 11, wherein the first image correction processportion, when deciding a correction coefficient of a frame, uses thecorrection coefficient of the frame and a correction coefficient of atleast one of frames which are input before and after the frame, to applya low pass filter process to the correction coefficient of the frame.13. The image correction process circuit according to claim 4, wherein ahysteresis width is set in at least one of the first threshold value andthe second threshold value.
 14. The image correction process circuitaccording to claim 2, further comprising a register for externallysetting various parameters that are referred to by the correctioncontrol portion when the correction control portion determines whetherthe image correction process is necessary or not for the input image andthe correction amount.
 15. The image correction process circuitaccording to claim 3, further comprising a register for externallysetting various parameters that are referred to by the correctioncontrol portion when the correction control portion determines whetherthe image correction process is necessary or not for the input image andthe correction amount.
 16. The image correction process circuitaccording to claim 4, further comprising a register for externallysetting various parameters that are referred to by the correctioncontrol portion when the correction control portion determines whetherthe image correction process is necessary or not for the input image andthe correction amount.
 17. The image correction process circuitaccording to claim 5, further comprising a register for externallysetting various parameters that are referred to by the correctioncontrol portion when the correction control portion determines whetherthe image correction process is necessary or not for the input image andthe correction amount.
 18. The image correction process device accordingto claim 10, wherein in the first image correction process portion, avalid luminance range of the luminance histogram, which is referred toduring a time of calculating a correction coefficient, is variably set.